package com.crazymo.binderpool;

import android.os.RemoteException;

/******************************************************************
 * @Copyright : (C), 2001-2021, ZHEJIANG DAHUA TECHNOLOGY CO.,LTD
 * @FileName : SecurityCenterImpl
 * @Author : 224967  Crazy.Mo
 * @Date : 2022/2/11 16:04
 * @Description :    
 * @History :
 * <author>  <time>  <version>   <desc>
 * 224967    修改时间    版本号       描述
 ******************************************************************/

public class SecurityCenterImpl extends ISecurityCenter.Stub {
    private final static char SECRET_CODE='^';

    @Override
    public String encrypt(String content) throws RemoteException {
        char[] chars=content.toCharArray();
        for (int i=0;i<chars.length;i++) {
            chars[i] ^= SECRET_CODE;
        }
        return new String(chars);
    }

    @Override
    public String decrypt(String content) throws RemoteException {
        return encrypt(content);
    }
}
